package com.tiwi.gmbdr;

import com.tiwi.gmbdr.constant.Global;
import com.tiwi.gmbdr.model.Question;

import android.app.Activity;
import android.os.Bundle;
import android.widget.RadioButton;
import android.widget.TextView;

public class QuestionsActivity extends Activity{

	private Question questionBean; 
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.question_activity);
		
		  // GridView gridview = (GridView) findViewById(R.id.question_activity);
		    
		 questionBean = Global.currentQuestion;
		
		TextView soal =  (TextView) findViewById(R.id.textSoal);
		RadioButton  jawabanA = (RadioButton) findViewById(R.id.radioA);
		RadioButton  jawabanB = (RadioButton) findViewById(R.id.radioB);
		RadioButton  jawabanC = (RadioButton) findViewById(R.id.radioC);
		RadioButton  jawabanD = (RadioButton) findViewById(R.id.radioD);
		
		
		soal.setText(questionBean.getNo_soal()+". "+questionBean.getSoal());
		jawabanA.setText(questionBean.getJawaban_a());
		jawabanB.setText(questionBean.getJawaban_b());
		jawabanC.setText(questionBean.getJawaban_c());
		jawabanD.setText(questionBean.getJawaban_d());
	}
	
	
	
}
